import React from 'react'
import {render} from 'react-dom'
import { Router, Route, Link, hashHistory, IndexRoute} from 'react-router'
// 引入主体样式文件
import './main.scss'

import layout from './components/layout.js'
import verifyCode from './components/sendVerifyCode.js'
import login from './components/login.js'
import records from './components/records.js'
import resetpwd from './components/resetpwd.js'
import today from './components/today.js'
import club from './components/club.js'
import userinfo from './components/userinfo.js'
import replay from './components/replay.js'
import favorite from './components/favorite.js'
import toprank from './components/toprank.js'
import history from './components/history.js'
import detail from './components/detail.js'
import accounts from './components/accounts.js'
import sync from './components/sync.js'
import grouplist from './components/grouplist.js'
import opponent from './components/opponent.js'
// import round from './components/round.js'
import './components/global.js'


// 引入Ant-Design样式 & Animate.CSS样式
import 'animate.css/animate.min.css'
// 配置导航
class Sider extends React.Component {
    constructor(props) {
        super(props)
    }

    render() {
        return (
            <myLayout></myLayout>
        )
    }
}

// 配置路由
render((
    <Router history={hashHistory} >
        <Route path="/" component={login}/>
        <Route path="/login" component={login}/>
        <Route component={layout}>
            <Route path="/verifyCode" component={verifyCode} />
            <Route path="/records" component={records} />
            <Route path="/resetpwd" component={resetpwd} />
            <Route path="/today" component={today} />
            <Route path="/club" component={club} />
            <Route path="/replay" component={replay} />
            <Route path="/favorite" component={favorite} />
            <Route path="/toprank" component={toprank} />
            <Route path="/accounts" component={accounts} />
            <Route path="/userinfo" component={userinfo} />
            <Route path="/detail" component={detail} />
            <Route path="/sync" component={sync} />
            <Route path="/history" component={history} />
            <Route path="/grouplist" component={grouplist} />
            <Route path="/opponent" component={opponent} />
        </Route>

    </Router>
), document.getElementById('app'))


import './cordova.js'
